<template>
  <div>
    我是c组件
    {{num2}}
    <button
    @click="btnclick">按钮</button>
  </div>
</template>

<script>

export default {
  props: ['num2'],
  data() {
    return {
      num:0
    }
  },
  methods: {
    btnclick() {
      this.num = this.num2
      console.log(this.num);
      this.num++

      this.$emit('ooo',this.num)

    }
  }
}
</script>

<style>
</style>
